#!/bin/sh


if [ ! -d "/sys/class/gpio/gpio93" ]; then
    echo 93 > /sys/class/gpio/export
    echo "in" > /sys/class/gpio/gpio93/direction
fi    

result=$(cat /sys/class/gpio/gpio93/value)
    if [ $result -eq 1 ]; then
        echo "干接点-1输入成功"
        echo "$(date):input1 测试成功" >> /userfs/all.txt
    else
        echo "干接点-1输入失败"
        echo "$(date):input1 测试失败" >> /userfs/all.txt
    fi
    echo "gpio_in_1 Begin execution"
